package cn.y.operation.framework.enums;


public enum ResponseMsgEnum {
    SUCCESS(0, "成功"),
    FAIL(-1, "失败"),

    NO_PERMISSION(403, "暂无权限"),

    PARAM_ERR(1000, "关键参数无效"),
    EXCEPTION_ERR(1001, "系统异常"),
    NO_DATA(1002, "查无数据"),
    INSERT_DATA_ERR(1003, "保存数据失败"),
    TIMEOUT(1004, "服务器超时"),
    GET_DATA_FAIL(1005, "获取数据失败"),
    DELETE_DATA_FAIL(1006, "删除数据失败"),
    UPDATE_DATA_FAIL(1007, "更新数据失败"),
    CAN_NOT_OPER_DATA(1008, "数据不可被操作"),
    DATA_FORMAT_ERR(1009, "数据格式错误"),
    DATA_STATUS_CAN_NOT_EDIT(1010, "数据状态不可修改"),

    ACC_NOT_EXIST(1100, "账号不存在"),
    ACC_EXIST(1101, "账号已存在"),
    USERNAME_OR_PASSWORD_ERROR(1102, "账号或密码错误"),
    ACC_PWD_ERR(1103, "密码错误"),
    ORG_PWD_ERR(1104, "原密码错误"),
    SYS_ACCOUNT_DEL_ERR(1105, "系统账号，不能删除"),
    SYS_ACCOUNT_DISENABLE_ERR(1106, "系统账号，不能禁用"),
    ACCOUNT_LOCKED(1107, "账户被锁定或未激活"),

    ROLE_NOT_EXIST(1200, "角色不存在"),
    ROLE_EXIST(1201, "角色已存在"),
    ROLE_BIND_USER_ERR(1202, "有用户关联了该角色，不能删除"),

    USER_NAME_IS_NULL(1300, "用户名不能为空"),
    USER_NAME_IS_USED(1301, "用户名已被占用"),
    //NAME_NOT_NULL (1302, "姓名不能为空"),
    NAME_NOT_USED(1302, "姓名不能占用"),
    NAME_NOT_NULL(1302, "姓名不能为空"),
    PERSONNUM_NOT_NULL_ERR(1305, "工号不能为空"),
    PERSONNUM_EXIST_ERR(1306, "工号已存在"),
    GENDER_NOT_NULL_ERR(1307, "性别不能为空"),
    GENDER_ERR(1308, "性别有误"),
    MOBILE_NOT_NULL_ERR(1309, "手机号不能为空"),
    MOBILE_EXIST_ERR(1310, "手机号已存在"),
    MOBILE_ERR(1311, "无效的手机号"),
    DEPT_NOT_NULL_ERR(1312, "部门不能为空"),
    DEPT_NOT_EXIST_ERR(1313, "部门不存在"),
    DEPT_EXIST_ERR(1314, "部门已存在"),

    READ_EXCEL_DATA_EMPTY(1400, "Excel数据为空"),
    READ_DATA_ERR(1401, "读取数据失败"),
    ZIP_HAS_NO_PIC_ERR(1402, "压缩包中没有包含图片"),
    NO_FACE_PIC_ERR(1403, "没有对应的人脸图片"),
    UPLOAD_PIC_ERR(1404, "上传人脸图失败"),
    UNZIP(1405, "解压压缩包"),
    READ_EXCEL(1406, "读取Excel文件"),
    IMPORT_DATA(1407, "导入数据"),
    IMPORT_END(1408, "导入结束"),
    EXPORTING(1409, "开始导出"),
    EXPORT_DATA(1410, "导出数据"),
    EXPORT_END(1411, "导出结束"),
    ZIP(1412, "打包数据"),
    EXPORTIN_NO_DATA(1413, "无数据导出"),
    FILE_PATH_MKDIRS_ERR(1414, "文件目录创建失败"),
    ;
    private final Integer code;
    private final String info;

    ResponseMsgEnum(Integer code, String info) {
        this.code = code;
        this.info = info;
    }

    public Integer getCode() {
        return this.code;
    }

    public String getInfo() {
        return this.info;
    }
}
